package com.zhanglinwei.openApiClient.model.response.lambda;

import lombok.Getter;
import lombok.Setter;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

@Getter
@Setter
public class ExampleLambdaResponse extends LambdaOpenApiResponse<ExampleLambdaResponse.ExampleDTO> {

    private List<ExampleDTO> data = new ArrayList<>();

    @Override
    public List<ExampleDTO> content() {
        return data == null ? Collections.emptyList() : data;
    }

    @Getter
    @Setter
    public static class ExampleDTO {
        private String code;
        private String name;
    }
}
